﻿using Orleans;
using Pay.Model;
using Pay.Model.Dto;
using Pay.Model.Interfaces;
using Pay.Model.Model;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Pay.Service
{
   public  interface IAliaccountService: IGrainWithStringKey
    {

        Task<List<QRCodeInfo>> GetByAmount(decimal amount, long[] ids);


        Task<List<AliAccountInfo>> GetAccountByUserId(long userId);
        /// <summary>
        /// 更新
        /// </summary>
        /// <param name="model"></param>
        /// <returns></returns>
        Task<bool> Update(AliAccountInfo model);
        /// <summary>
        /// 根据商户code获取key
        /// </summary>
        /// <param name="code"></param>
        /// <returns></returns>
        Task<MerchantInfo> GetKeyByCode(string code);
        Task<AliAccountInfo> GetInfoBySystemName(string systemName);
        Task<bool> IsContainSystemAccount(string systmeName);

        Task<AliAccountInfo> GetAccountById(long Id);

        Task<long> Add(AliAccountInfo model);

        Task<bool> Forbidden(AliAccountInfo model);

        Task<bool> Delete(AliAccountInfo model);


        Task<IPagedOutput<AliAccountInfo>> GetPage(string searchWord, long userId, DateTime? timeBegin = null, DateTime? timeEnd = null, int offset = 10, int rows = 1);


        Task<long> Add(QRCodeInfo model);

    }
}
